package edu.sctu.practice.class02.liqing.assignment03.assignment03_01;

/**
 * Created by 123456 on 2015/10/22.
 */
public class Rectangle extends GeometricObject {
    public double length;
    public double width;
    public double Area;
    public double  Preimeter;
    @Override
    public double findArea(){
        Area = length * width;
        return Area;
    }
    @Override
    public double findPerimeter(){
     Preimeter = 2 * width + 2 * length;
        return Preimeter;
    }
    public Rectangle(String color,double length,double width){
        super(color);
        this.length = length;
        this.width = width;
    }
public String toString(){
    return "矩形：";
}
}